<template>
	<view>
		<store v-if="PageCur=='store'"></store>
		<total v-if="PageCur=='total'"></total>
		<view class="cu-bar tabbar bg-white shadow foot">
			<view class="action" @click="NavChange" data-cur="store">
				<view :class="['tab-icon-block', PageCur == 'store'?'bg-blue':'bg-white']">
					<text :class="['ph-shengchangaiyao', 'font-size34', PageCur == 'store'?'text-white':'text-gray']"></text>
				</view>
				<view :class="PageCur=='store'?'text-blue':'text-gray'">板坯库存</view>
			</view>
			<view class="action" @click="NavChange" data-cur="total">
				<view :class="['tab-icon-block', PageCur == 'total'?'bg-blue':'bg-white']">
					<text :class="['ph-kucuntongji', 'font-size34', PageCur == 'total'?'text-white':'text-gray']"></text>
				</view>
				<view :class="PageCur=='total'?'text-blue':'text-gray'">库存统计</view>
			</view>
		</view>
	</view>
</template>

<script>
	import store from './store.vue'
	import total from './total.vue'
	export default {
		components: {
			store,
			total
		},
		data() {
			return {
				PageCur: 'store',
			}
		},
		methods: {
			NavChange: function(e) {
				this.PageCur = e.currentTarget.dataset.cur
			}
		}
	}
</script>

<style>
</style>
